POV-Ray : Newsgroups : povray.programming : Win32 Console POV-Ray : Re: Win32 Console POV-Ray Server Time
29 Jul 2024 00:26:41 EDT (-0400)
  Re: Win32 Console POV-Ray  
From: Alexander Enzmann
Date: 24 Nov 1999 07:24:26
Message: <383BD96F.47668841@mitre.org>
Thorsten Froehlich wrote:
> 
> In article <383ADE3C.61F2BC9E@buckosoft.com> , Dick Balaska
> <dic### [at] buckosoftcom>  wrote:
> 
> > So if your code is using floats,
> ...
> 
> That is wrong! There is no time for conversion required, as it is a trivial
> to "cut off" the exponent (reduce it from 11 to 8 bit) and the significant
> (reducing it from 52 to 23 bit) when loading/storing them.
> As a matter of fact, internally all current processors store floating-point
> numbers as if they were doubles (or whatever other most precise internal
> format they support). When performing the calculation as single-precision,
> the other bits are just not taken into account.


It is a little more curious still.  You can force an Intel FPU to work
in several precision modes (32, 64, 80).  There are differences in the
total # of clocks from beginning to end based on how much data needs to
be pushed onto the FPU stack and the precision you run the FPU.

A secondary consideration is that with the tiny on chip cache of the
Intel chips, using larger data sizes (8 byte doubles) will cause misses
more often than using 4 byte singles.  When this happens you get a huge
performance hit.

Understanding and programming around these types of things is very
important to games programmers and real time sim packages.  It is also
quite platform dependent.

Xander


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.